package com.woniuxy.controller;


import com.woniuxy.service.VoteOptionService;
import com.woniuxy.util.Result;
import org.springframework.web.bind.annotation.RequestMapping;

import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;

/**
 * <p>
 *  前端控制器
 * </p>
 *
 * @author zhouzhou
 * @since 2022-06-23
 */
@RestController
public class VoteOptionController {

    @Resource
    private VoteOptionService voteOptionService;

    //option添加在topicController
    /////*****

    @RequestMapping("/getOptionById")
    public Result getAllOptionByTopicId(Integer id){
        Result result = voteOptionService.getAllTopic(id);
        return result;
    }
}

